 #define _CRT_SECURE_NO_WARNINGS
#include <stdio.h>

int main() 
{
    int i, n;
    long fac = 1;

    printf("Please enter n:");
    scanf("%d", &n);

    for (i = 1; i <= n; i++) 
    {
        fac *= i;
    }

    printf("%d! = %ld\n", n, fac);

    return 0;
}